package my.dataCollection.busi.processor;

import my.dataCollection.base.IProcessor;
import my.dataCollection.base.vo.HandleVO;

import org.apache.commons.lang.StringUtils;

import com.google.gson.Gson;


public class JSONProcessor implements IProcessor {

	@Override
    public boolean Handle(HandleVO vo) {

		String str = vo.getCrawlerStr();
		if(StringUtils.isNotEmpty(str)){
			
			Gson gson = new Gson();			
			vo.setResultSet(gson.fromJson(str, vo.getResultSet().getClass()));
			return true;
		}
		
		return false;
    }


}
